package gui;

import java.awt.BorderLayout;
import java.awt.Color;
import java.awt.Dimension;
import java.awt.Image;

import javax.swing.JButton;
import javax.swing.JPanel;


public class MainPanel extends JPanel{
	public Image img;
	VideoPanel vp;
	public JPanel controlPanel;
	public MainPanel(){
		setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
		setLayout(new BorderLayout(10,10));		
		vp=new VideoPanel(640,480);
		controlPanel = new JPanel();
		setBackground(Color.BLUE);
		add(vp,BorderLayout.CENTER);
		controlPanel.setLayout(null);
		
		controlPanel.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 1, true));
		controlPanel.setSize(1000, 400);
		Dimension dim=new Dimension(500,1000);
		controlPanel.setPreferredSize(dim);
		controlPanel.add(new JButton("laaaaa2"));
		add(controlPanel,BorderLayout.LINE_END);
		setOpaque(false);
	}
	public void drawImage(Image img){
		vp.img = img;
	}
}
